﻿using System.Collections.Generic;
using System.Data;
using System.ServiceModel;

namespace APMABusinessLogicCoreLib
{
    [ServiceContract]
    public interface IBusinessLogicCore
    {
        [OperationContract]
        string GetMessageFromBL();

        [OperationContract]
        int ValidateUser(string login, string password);

        [OperationContract]
        int CreateUser(Dictionary<string, object> parameters, string login);

        [OperationContract]
        int RemoveUser(int id, string login);

        [OperationContract]
        int UpdateUser(Dictionary<string, object> parameters, string login);

        [OperationContract]
        int UpdateUserWithPassword(Dictionary<string, object> parameters, string login);

        [OperationContract]
        int CreateProject(Dictionary<string, object> parameters, string login);

        [OperationContract]
        int RemoveProject(int id, string login);

        [OperationContract]
        int UpdateProject(Dictionary<string, object> parameters, string login);

        [OperationContract]
        int ClearLogs();

        [OperationContract]
        DataTable GetLogsList();

        [OperationContract]
        DataTable GetTasksList();

        [OperationContract]
        int AddNewTask(Dictionary<string, object> parameters, string login);

        [OperationContract]
        int RemoveTask(int id, string login);

        [OperationContract]
        int UpdateTask(Dictionary<string, object> parameters, string login);

        [OperationContract]
        DataTable GetUsersList();

        [OperationContract]
        DataTable GetProjectsList();

        [OperationContract]
        DataTable GetIterationsList();

        [OperationContract]
        DataTable GetIterationsListId();

        [OperationContract]
        int AddNewIteration(Dictionary<string, object> parameters, string login);

        [OperationContract]
        int RemoveIteration(int id, string login);

        [OperationContract]
        int UpdateIteration(Dictionary<string, object> parameters, string login);

        [OperationContract]
        DataTable GetUserStoriesListNames();

        [OperationContract]
        DataTable GetUserStoriesList();
        
        [OperationContract]
        int AddNewUserStory(Dictionary<string, object> parameters, string login);

        [OperationContract]
        int RemoveUserStory(int id, string login);

        [OperationContract]
        int UpdateUserStory(Dictionary<string, object> parameters, string login);

        [OperationContract]
        DataTable GetReleasesList();

        [OperationContract]
        int AddNewRelease(Dictionary<string, object> parameters, string login);

        [OperationContract]
        int RemoveRelease(int id, string login);

        [OperationContract]
        int UpdateRelease(Dictionary<string, object> parameters, string login);

        [OperationContract]
        DataTable GetTeamStatusList();

        [OperationContract]
        DataTable GetTeamStatusListWithFilter(Dictionary<string, object> parameters);

        [OperationContract]
        int AddFilesToTask(DataTable dataTable, int taskId);

        [OperationContract]
        DataTable GetFilesListByTask(int taskId);

        [OperationContract]
        DataTable GetBurnUpDown(int iterationId);

        [OperationContract]
        DataTable GetBurnUpDownChart(int iterationId);
    }
}
